#include "glstring.h"

// Here are the fonts: 
/*
LPVOID glutFonts[7] = { 
    GLUT_BITMAP_9_BY_15, 
    GLUT_BITMAP_8_BY_13, 
    GLUT_BITMAP_TIMES_ROMAN_10, 
    GLUT_BITMAP_TIMES_ROMAN_24, 
    GLUT_BITMAP_HELVETICA_10, 
    GLUT_BITMAP_HELVETICA_12, 
    GLUT_BITMAP_HELVETICA_18 
}; 
*/


// Here is the function 
void glutPrint(float x, float y, float z, char* text, float *rgba, void *font)
{ 
	int blending = 0; 
    if(!text) return; 

    if(glIsEnabled(GL_BLEND)) blending = 1; 
    glEnable(GL_BLEND); 
    glColor4fv(rgba); 
    glRasterPos3f(x,y, z); 
    while (*text) { 
        glutBitmapCharacter(font, *text); 
        text++; 
    } 
    if(!blending) glDisable(GL_BLEND); 
}

